{extend name="./public/base"/}
{block name="alt"}评论列表{/block}
{block name="alter"}评论列表{/block}
{block name="title"}BangBang视频评论列表{/block}
{block name="main"}

			<div class="row">
                    <div class="col-12">
                        <div class="card">
                            <div class="card-block">
                                <div class="card-body">
                                        <table class="table table-striped  mt-3">
                                            <thead>
                                                <tr>
                                                    <th scope="col"><p class="text-center">状态</p></th>
                                                    <th scope="col"><p class="text-center">序号</p></th>
                                                    <th style="width: 25%;" scope="col"><p class="text-center">评论内容</p></th>
                                                    <th scope="col"><p class="text-center">评论日期</p></th>
                                                    <th scope="col"><p class="text-center">用户名</p></th>
                                                    <th scope="col"><p class="text-center">视频名</p></th>
                        
                                                    <th scope="col"><p class="text-center">操作</p></th>
                                                </tr>
                                            </thead>
                                            <tbody>
                                                {volist name="comments" id="comment" key="k"}
                                                <tr>
                                                    <td>
                                                        {if condition="$comment.cstatus==0"}<p class="text-center text-success">正常</p>
                                                        {else/}<p class="text-center text-danger">封禁</p>
                                                        {/if}
                                                    </td>
                                                    <td><p class="text-center">{$k+($page-1)*10}</p></td>
                                                
                                                    <td><p class="text-center">{$comment.content}</p></td>
                                                    
                                                    <td><p class="text-center">{$comment.cdate}</p></td>
                                                    
                                                    <td><p class="text-center">{$comment.uname}</p></td>
                                                     <td><p class="text-center">{$comment.videoname}</p></td>
                                                   
                                                    <td class="text-center">
                                                        
                                                        <div class="btn-group">
    <button type="button" class="btn btn-danger dropdown-toggle" data-toggle="dropdown">
        <span class="glyphicon glyphicon-cog">封禁/解封</span>
    </button>
    <ul class="dropdown-menu" role="menu">
        <li>
            {if condition="$comment.cstatus==0"}
           &nbsp;<a class="text-success" href="{:url('shield1',['cid'=>$comment.cid,'uid'=>$comment.uid])}" onclick="return confirm('确认发送该条违法信息')">&nbsp;1.您的评论包含违法信息</a>
           {else/} <button type="button" class="btn btn-default" disabled="disabled">1.您的的评论包含违法信息</button>
            {/if}
        </li>

        <li>
             {if condition="$comment.cstatus==0"}
           &nbsp;<a class="text-success" href="{:url('shield2',['cid'=>$comment.cid,'uid'=>$comment.uid])}" onclick="return confirm('确认发送该条违法信息')">&nbsp;2.您的评论包含诋毁本网站信息</a>
           {else/} <button type="button" class="btn btn-default" disabled="disabled">2.您的评论包含诋毁本网站信息</button>
            {/if}
        </li>
        <li>
            {if condition="$comment.cstatus==0"}
           &nbsp;<a class="text-success" href="{:url('shield3',['cid'=>$comment.cid,'uid'=>$comment.uid])}" onclick="return confirm('确认发送该条违法信息')">&nbsp;3.您的评论包含辱骂他人信息</a>
           {else/} <button type="button" class="btn btn-default" disabled="disabled">3.您的评论包含辱骂他人信息</button>
            {/if}
        </li>
         <li>
             {if condition="$comment.cstatus==1"}
           &nbsp;<a class="text-danger" href="{:url('shield4',['cid'=>$comment.cid,'uid'=>$comment.uid])}" onclick="return confirm('确认解封')">&nbsp;4.解除封禁</a>
           {else/} <button type="button" class="btn btn-default" disabled="disabled">4.解除封禁</button>
            {/if}
        </li>
        
    </ul>
</div>
                                                       
                                                    </td>
                                              
                                                </tr>
                                                {/volist}
                                                
                                                
                                            </tbody>
                                        </table>
                                        {$comments->render()}
                                </div>
                            </div>
                        </div>
                    </div>
                </div>

{/block}